Part Number Hot Search : 
78M05 AXLGS52F 16C55 R43391 T1300 BSS79BL 45027 T66N20Q
Product Description
Full Text Search
 

To Download AN4127 Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  june 2012 doc id 023304 rev 1 1/27 AN4127 application note demonstration board for bluetooth ? module class 2 sbt2632c2a.at2 introduction this document describes the steval-spbt3atv3 demonstration board (dongle) for the bluetooth ? class 2 spbt2632c2a.at2 module. the dongle includes the module under evaluation, an rf antenna, and a usb connector. the usb connector is used to connect the dongle with a pc, to access the bluetooth module and to supply the dongle. the steval-spbt3atv3 is an easy solution to test and operate with the spbt2632c2a.at2 module and familiarize the user with the embedded fw which enables the creation of a bluetooth link with simple at commands. the at command list is detailed in the um1547 user manual. this document introduces the main technical characteristics of the dongle and includes a quick start guide to get started with the steval-spbt3atv3. dongle features: based on v3.0 bluetooth class 2 module, spbt2632c2a.at2 usb interface and power supply supported reprogrammability via usb interface reset button antenna onboard rohs compliant figure 1. steval-spbt3atv3 dongle www.st.com
contents AN4127 2/27 doc id 023304 rev 1 contents 1 demonstration board usage limitation . . . . . . . . . . . . . . . . . . . . . . . . . . 3 2 recommended operating conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 3 dongle layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 4 i/o connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 4.1 pad description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 4.2 reset switch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 5 dongle schematic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 6 getting started . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 6.1 dongle installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 6.2 setup and connect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 6.2.1 startup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 6.2.2 inquiry and available services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 6.2.3 command and answer syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 6.2.4 gpio and led . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 appendix a usb driver installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 7 revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
AN4127 demonstration board usage limitation doc id 023304 rev 1 3/27 1 demonstration board usage limitation the dongle based on the spbt2632c2a.at2 module is not qualified; it is a pure demonstration tool only for evaluation purposes and not a product in itself. 2 recommended operating conditions table 1. recommended operating conditions symbol parameter condition min. typ. max. unit v dd board supply voltage -40 c < t < 85 c 4.5 5 5.5 v top operating case temperature range -40 +85 c
dongle layout AN4127 4/27 doc id 023304 rev 1 3 dongle layout figure 2. dongle component layout, front side figure 3. dongle component layout, bottom side
AN4127 i/o connections doc id 023304 rev 1 5/27 4 i/o connections 4.1 pad description other than the usb plug, some pads are also available. in fact pad1 to pad13 make the spbt2632c2a.at2 pins available to the user. ta b l e 2 gives a description of these pads. figure 4. front side connection figure 5. bottom side connection 1 3 4 1 3 pad 1 to 3 pad 4 to 1 3 led1 led 3 led2 am12669v1 j1 jtag connector am12670v1 table 2. pad connections description pa d 1 boot0 - boot pin used for firmware downloading - used for testing purposes 2 3.3 v (module ? led1 is connected to this pad) 3 resetn - reset - connected in parallel to onboard reset switch 4gnd 5 +5 v (usb) 6 lpo (external 32.768 khz frequency input to allow deep sleep and sniff mode bluetooth module functional states) 7 gpio07 ? general purpose i/o 8 gpio01 ? general purpose i/o (1) (led2 is connected to this gpio) 9 gpio02 ? general purpose i/o (1) 10 gpio03 ? general purpose i/o (1) 11 gpio04 ? general purpose i/o (1) (led3 is connected to this gpio) 12 gpio06 ? general purpose i/o (1) 13 gpio05 ? general purpose i/o
i/o connections AN4127 6/27 doc id 023304 rev 1 4.2 reset switch a reset switch sw1 is present on the dongle. when sw1 is pushed, spbt2632c2a.at2 is forced to reset. the following prompt is displayed on the screen: at-ab - commandmode at-ab bdaddress xxxxxxxxxxxx figure 6. reset switch jtag 1jtrst 2jtdo 3jtck 4jtms 5jtdi 6 nreset (max. voltage 2.5 v) 7 + 3.3 v 8gnd 1. default configuration - a different configurat ion may be chosen (see the spbt2632c2a.at2 datasheet). table 2. pad connections (continued) description re s et s witch am12671v1
AN4127 dongle schematic doc id 023304 rev 1 7/27 5 dongle schematic figure 7. dongle electrical drawing !-v 3$ '  5 . 3$ '  &  q 3$ '  3$ '  73 9 9b86% 9&& 3$ '  3$ '  3$ '  *3,263,b0,62 *3,263,b66, 6b:6 5  2kp /(' *5((1 3$ '  5  2kp /(' *5((1 3$ '  986% 9&& 3$ '  - &21         & x 9 & q -3 .- 5 &  q 6: 6:386+%87721 5(6(71 & x) -3 576b&3 %227 5 . 9 8$ 0&37(77 9lq  *1'  9rxw  &  q &  x 9 &  x 9 *3,2 & q &  q *3,2'$& ,& /'605 9lq  *1'  %\ 3dvv  9rxw  ,1+,%,7  *3,263,b&/., 6b&. *3,263,b026,, 6b6' 73 9b&3 !.4%..! %7 63%7&$$7 %702'8/( &76  %227  *1'  5(6(7  576  3$-7&. 37 3$-7', 37 3%-7'2 37 3%-1 7567 37 5;'  7;'  3$-706 37 *3,2  9,1  *3,2  *3,2  *3,2  *3,2  *3,2  1567 37 /32  *3,2  5 10 !,4%2.!4) 6%$%6)#% 7$17 /32 *3,2 ,& 67* ',5   9&&%  ',5   %  %  2(  *1'  $  $  9&&$  53"$ 53" '.$ 53"$ 53" 6cc 9 &  q 5 2kp 5 2kp 9b+& 9 5;'b&3 &76b&3 7;'b&3 5 1 0 :$51,1*q5(6(7vljqdoohyhopd[ 9 ,& 0&37( 9lq  *1'  9rxw  & x 9 ,& 86%8): '  *1'  '  '  9  '  & x) - 86%0$/(&211(&725     3$ '  q5(6(7 -7' , -7& . -70 6 -7' 2 3$ '  -75 67 5  2kp /(' *5((1 3$ '  ,& &3 '  '  9gg  5(*,1  9%86  '&'  5,  *1'  567  1&  6863(1'  6863(1'  1&  1&  1&  1&  1&  1&  1&  1&  1&  1&  &76  576  5;'  7;'  '65  '75 
getting started AN4127 8/27 doc id 023304 rev 1 6 getting started 6.1 dongle installation the bluetooth spbt2632c2.at2 module and the related dongle do not need any bluetooth driver on the host processor. however, before using a new usb device the user must install it on their pc. if the usb driver is not present on the pc, it is necessary to apply a simple installation procedure as follows: step 1: simply plug the steval-spbt3atv3 into any available usb port. the computer responds with the following two messages: figure 8. usb drive installation first and second step step 2: next, a ?found new hardware wizard? installation window opens. select ?yes, this time only? to locate the drivers from the microsoft ? website. figure 9. wizard installation first step click ?next? to install automatically.
AN4127 getting started doc id 023304 rev 1 9/27 figure 10. wizard installation second step the steval-spbt3atv3 usb to uart controller and virtual com port driver is now installed. step 3: the ?found new hardware wizard? now opens again in order to install the usb device driver. select ?yes, this time only? to locate the drivers from the microsoft website. figure 11. wizard installation third step the following message appears: figure 12. wizard installation completed
getting started AN4127 10/27 doc id 023304 rev 1 step 4: open the windows ? device manager application to verify correct installation, and see which com port has been assigned to the steval-spbt3atv3 bluetooth serial device. the steval-spbt3atv3 is usually assigned the same virtual com port each time it is inserted (unless there are other virtual com devices altering port assignments). two device drivers for the steval-spbt3atv3 bluetooth device should be seen here. figure 13. windows device manager the cp2102 chip provides the function of using standard uart serial communications from the computer via the universal serial bus, and interfaces directly to the bluetooth module inside the steval-spbt3atv3 bluetooth serial adapter. if usb driver wizard installation fails, follow appendix a: usb driver installation installation procedure. 6.2 setup and connect the purpose of this section is to describe all the necessary steps to establish a connection between two bluetooth steval-spbt3atv3 dongles realizing a serial line/cable replacement application. two pcs and two steval-spbt3atv3 boards are needed to perform the connection.
AN4127 getting started doc id 023304 rev 1 11/27 figure 14. basic setup (please refer to the um1547 user manual for the listing and meaning of the at commands.) 6.2.1 startup two dongles are needed to perform the connection. each dongle has its own bd address. suppose 0080e1f00001 for dongle1 and 0080e1f00002 for dongle2. each dongle has the following factory default: ? uart: 115200 baud rate, no parity, 1 stop bit, 8 data bits ? local name: ?amp'ed up!? ? class of device: misc. device ? profile: spp (serial port profile) ? service name: ?amp-spp? ? deep sleep: disabled ? page and inquiry scan: 1.28s interval, 11ms duration ? security: disabled ? bonding pin: ?1234? ? bonding allowed: always enabled plug each dongle into the pc using the usb connector open the hyperterminal program on both pcs and create a new connection ?at command?. !-v 'rqjoh 'rq joh 6fuhhq 'rq joh 6fuhhq 'rqjoh
getting started AN4127 12/27 doc id 023304 rev 1 figure 15. connection setup set the connection port: figure 16. connection port setup and configure it: figure 17. port parameters
AN4127 getting started doc id 023304 rev 1 13/27 with the following parameters: ? select the proper com line (com1, com2??) ? set baud rate = 115000 (default baud rate of spbt2632c2.at2 module) ? set data bits = 8 ? set stop bits = 1 ? set parity = none ? set flow control = none from the menu file set the at command connection properties: figure 18. connection properties setup the dongle is ready to use: ? press the reset switch on the dongle ? on the screen, the prompt followed by the module bluetooth address should appear: figure 19. at command prompt ?at-ab -commandmode -? ?at-ab bdaddress xxxxxxxxxxxx? !-v
getting started AN4127 14/27 doc id 023304 rev 1 figure 20. bdaddress dongle1, dongle2 from now on the user can operate the dongle using the at commands. 6.2.2 inquiry and available services before establishing a connection, the dongle must know which bluetooth devices are present and which services are offered. each module has its own address which identifies the module itself in the network. the bd address can be found during the discovery phase. if the bd address of the bluetooth device the user wants to connect to is known, the inquiry procedure can be omitted. discovery: ? at+ab discovery this command returns the number of responses of nearby devices and then the individual responses with the bd address, and device name. the number of devices returned is limited to 10. inquiry is performed with an interval of 10.24 seconds. the devices are reported in the same order as the original inquiry results. for each name or service name request that is successful, the response uses the returned names in the following format: ? at-ab device [bd addr] [name] ? at-ab device [bd addr] unknown as a consequence of a discovery command issued by dongle1, the following lines are displayed:
AN4127 getting started doc id 023304 rev 1 15/27 figure 21. discovery dongle1 note: in the case of 1 device found. service: to verify, at the same time, which kind of service is available, use the command: at+ab discovery [cod] [profile] response is: at-ab device [bd addr] [name] as a consequence of a discovery command for spp service issued by dongle1, the following appears on the screen: figure 22. service dongle1 note: in the case of 1 device found. bonding: bonding is used when an application needs to pair with another remote device. devices must be enabled to bond, with this aim, the enablebond command is used. the bd address, pin and timeout parameters are optional. ? at+ab enablebond if the operation is successful, the response is: ? at-ab bondenabled to bond devices the ?bond command? is used where the device address and the identification number (pin) is specified. the command is: ? at+ab bond [bd addr] [pin]
getting started AN4127 16/27 doc id 023304 rev 1 if the request is successfully submitted, the response is: ? at-ab bondpending [bd addr] if the operation is successful, the response is: ? at-ab bondok if it fails: ? at-ab bondfail in this case, dongle1 is requesting a bonding with dongle2. figure 23. bonding dongle1, dongle2 connection: once the dongle knows the device present and the service offered, the command to set up connection is: ? at+ab sppconnect [bd addr] [service] if the connection is successful, the response is: ? at-ab connectionup ? at-ab -bypassmode- at this point the connection is established. the dongles can send and receive data. in this case, dongle1 knows the address of dongle2, and wants to connect to dongle2:
AN4127 getting started doc id 023304 rev 1 17/27 figure 24. connection dongle1, dongle2 now the two dongles are connected to one another and in -bypassmode-. in other words, everything typed on a terminal is transferred to the other via the bluetooth link and vice versa. in -bypassmode- the dongle doesn't answer the commands. if, for example, the user needs to change some parameters of a dongle, it?s necessary to switch to -commandmode-, giving the ?escape command?. the escape command is a special sequence of characters followed by at least two seconds of inactivity on the serial port. the escape command sequence is: ^ #^$^%. figure 25. escape dongle1, dongle2 as can be noted, the escape command given to dongle1 doesn't affect dongle2 which remains in -bypassmode-. connection between the two dongles is still active; to return to the ?exchange data? situation, dongle1 must be re-configured in -bypassmode- with the command ?bypass?.
getting started AN4127 18/27 doc id 023304 rev 1 figure 26. return to -bypassmode- dongle1, dongle2 now the two dongles can exchange data again. disconnection: the sppdisconnect command is used to terminate a connection with the remote device. ? at+ab sppdisconnect if the disconnection is successful, the response is: ? at-ab sppconnectionclosed sppdisconnect is a command; it is recognized and accepted by the dongle only if the dongle is in -commandmode-. if the dongle is in -bypassmode-, send the ?escape command? before giving the disconnection command. figure 27. disconnection dongle1, dongle2
AN4127 getting started doc id 023304 rev 1 19/27 information related to successful disconnection is displayed on both screens. smart cable setup: the smart cable setup command is used to enable and configure a smartcable device. a device bd address is specified with which to automatically establish a connection, replacing the need for at connection commands. it is stored in the non-volatile memory. the command is: ? at+ab smartcablesetup [bd addr] [attempts] [interval] if the command is successful, the response is: ? at-ab smartcableconfigdone in this case, suppose an automatic connection of dongle1 to dongle2 at power-on is needed, with the possibility to retry for 5 times with an interval of 1 sec between each retry. the command is: ? at+ab smartcablesetup 0080e1f00002 5 1 this command is stored inside the non-volatile memory and executed at power-on. in case dongle2 is already powered: figure 28. smart cable dongle1, dongle2 if dongle2 is not powered or not available, dongle1 automatically retries 5 times. figure 29. automatic retrial dongle1 if dongle2 is present, dongle1 automatically connects. if dongle2 is unplugged, connection fails. however, connection is automatically restored if dongle2 is again plugged in during the interval of retrial assigned to dongle1.
getting started AN4127 20/27 doc id 023304 rev 1 figure 30. automatic connection dongle1, dongle2 delete smart cable setup: the command to remove the smartcablesetup is: ? at+ab deletesmartcable if the operation is successful, the answer is: ? at-ab deletesmartcabledone to give the command the dongle must be in; -commandmode-. erase bond table: the erase bond table command must be used to clear all the bonded device entries: ? at+ab erasebondtable if the operation is successful, the answer is: ? at-ab bondtableerased 6.2.3 command and answer syntax the syntax of the commands is fixed and cannot be changed, the prefix for each command is at+ab. each command has an answer which is preceded by the prefix at-ab; this identifier can be changed by means of the at+ab config command. if it is necessary to change the prefix of the answer from at-ab to ?>>? on dongle1, the steps to follow are shown in figure 31 :
AN4127 getting started doc id 023304 rev 1 21/27 figure 31. change syntax dongle1 note: change reply prefix. 6.2.4 gpio and led the spbt2632c2a.at2 has several pins which can be configured as gpios (gpio01 to gpio07). if gpio function is selected, gpio direction (input/output) and gpio level can be chosen by means of the at commands. gpio must be configured for output or input using the proper command: ? at+ab gpioconfig [gpio pin] i for input ? at+ab gpioconfig [gpio pin] o for output once configured, the gpio port can be read or written with the commands: ? at+ab gpiowrite [gpio pin] 1 write 1 ? at+ab gpiowrite [gpio pin] 0 write 0 ? at+ab gpioread [gpio pin] read on the dongle there are 2 leds connected to gpios: led2 connected to gpio01 and led3 to gpio004. each led can be switched on/off by driving the corresponding gpio with the proper at command.
getting started AN4127 22/27 doc id 023304 rev 1 example: figure 32. gpio set dongle1
AN4127 usb driver installation doc id 023304 rev 1 23/27 appendix a usb driver installation if usb driver wizard installation fails, the dongle can be installed using the driver available on the silicon lab website at www.silabs.com/support/pages/support.aspx?productfamily=usb+to+uart&partnumber =cp2102. insert the dongle into a usb port on the pc, follow the steps described in section 6.1 of this document. figure 33. usb driver installation launch figure 34. license agreement
usb driver installation AN4127 24/27 doc id 023304 rev 1 figure 35. wizard installation 1 figure 36. wizard installation 2 figure 37. wizard installation 3 !-v
AN4127 usb driver installation doc id 023304 rev 1 25/27 figure 38. wizard installation terminated figure 39. installation completed the usb driver installation is now complete.
revision history AN4127 26/27 doc id 023304 rev 1 7 revision history table 3. document revision history date revision changes 21-jun-2012 1 initial release.
AN4127 doc id 023304 rev 1 27/27 please read carefully: information in this document is provided solely in connection with st products. stmicroelectronics nv and its subsidiaries (?st ?) reserve the right to make changes, corrections, modifications or improvements, to this document, and the products and services described he rein at any time, without notice. all st products are sold pursuant to st?s terms and conditions of sale. purchasers are solely responsible for the choice, selection and use of the st products and services described herein, and st as sumes no liability whatsoever relating to the choice, selection or use of the st products and services described herein. no license, express or implied, by estoppel or otherwise, to any intellectual property rights is granted under this document. i f any part of this document refers to any third party products or services it shall not be deemed a license grant by st for the use of such third party products or services, or any intellectual property contained therein or considered as a warranty covering the use in any manner whatsoev er of such third party products or services or any intellectual property contained therein. unless otherwise set forth in st?s terms and conditions of sale st disclaims any express or implied warranty with respect to the use and/or sale of st products including without limitation implied warranties of merchantability, fitness for a particular purpose (and their equivalents under the laws of any jurisdiction), or infringement of any patent, copyright or other intellectual property right. unless expressly approved in writing by two authorized st representatives, st products are not recommended, authorized or warranted for use in military, air craft, space, life saving, or life sustaining applications, nor in products or systems where failure or malfunction may result in personal injury, death, or severe property or environmental damage. st products which are not specified as "automotive grade" may only be used in automotive applications at user?s own risk. resale of st products with provisions different from the statements and/or technical features set forth in this document shall immediately void any warranty granted by st for the st product or service described herein and shall not create or extend in any manner whatsoev er, any liability of st. st and the st logo are trademarks or register ed trademarks of st in various countries. information in this document supersedes and replaces all information previously supplied. the st logo is a registered trademark of stmicroelectronics. all other names are the property of their respective owners. ? 2012 stmicroelectronics - all rights reserved stmicroelectronics group of companies australia - belgium - brazil - canada - china - czech republic - finland - france - germany - hong kong - india - israel - ital y - japan - malaysia - malta - morocco - philippines - singapore - spain - sweden - switzerland - united kingdom - united states of america www.st.com


▲Up To Search▲   

 
Price & Availability of AN4127

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X